import Vue from 'vue'
import VueRouter from 'vue-router'
import Recommend from '../views/Recommend.vue'
import index from '../views/index.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'index',
    component:index
  },
  {
    path: '/Recommend',
    name: 'Recommend',
    component:Recommend
  },
  {
    path: '/hot',
    name: 'Hot',
    component:()=>import("@/views/Hot")
  },
  {
    path: '/search',
    name: 'Search',
    meta:{hideNav:true},
    alias:["/searchali"],
    component: ()=>import("@/views/Search")
  },
  {
    path:'/playlist/:listid',
    name:'PlayList',
    meta:{hideplay:true},
    props:true,
    component:()=>import("@/views/PlayList")
  }
]

const router = new VueRouter({
  mode: 'hash',
  base: process.env.BASE_URL,
  routes
})

export default router
